<?xml version="1.0" encoding="UTF-8"?>
<!--
To change this license header, choose License Headers in Project Properties.
To change this template file, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:p="http://primefaces.org/ui">
    <body>
        <h:form>
            <p:growl id="messages"/>

            <p:menubar >
                <p:menuitem value="MeteoCal" url="/users/home.xhtml?faces-redirect=true"/>
                <p:menuitem value="Search Users" icon="ui-icon-search" url="/users/searchUser.xhtml?faces-redirect=true"/>
                <p:menuitem value="Notifications" icon="ui-icon-help" url="/users/notification.xhtml?faces-redirect=true"/>

                <p:submenu label="#{usersView.loggedUser.name}" icon="ui-icon-gear">
                    <p:menuitem value="Share calendar" actionListener="#{menuView.shareCalendar}" icon="ui-icon-disk" update="messages"/>
                    <p:menuitem value="Settings" outcome="/users/profile.xhtml?faces-redirect=true" icon="ui-icon-gear" update="messages"/>
                    <p:separator/>
                    <p:menuitem value="Logout" action="#{loginView.logout}" icon="ui-icon-close" ajax="false"/>
                </p:submenu>
            </p:menubar>
        </h:form>
    </body>
</html>
